package com.tengroup.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.tengroup.entity.UserInfoEntity;

public interface UserService extends IService<UserInfoEntity> {
    boolean addUser(UserInfoEntity user);
    UserInfoEntity getUserById(Long id);
    boolean updateUser(UserInfoEntity user);

    UserInfoEntity findUserByUsername(String username);
    void registerUser(String username, String password) throws Exception;
    boolean login(String username, String password) throws Exception;
    int getUserClassByUsername(String username);


    IPage<UserInfoEntity> Query(UserInfoEntity userInfoEntity, int pageNo, int pageSize);
    IPage<UserInfoEntity> Query(UserInfoEntity user);

    UserInfoEntity findByEmail(String email);
}
